package edu.unmsm.ocaa.sisocaa.integracion.dao.impl;

import org.springframework.dao.DataAccessException;
import org.springframework.orm.ibatis.support.SqlMapClientDaoSupport;
import org.springframework.stereotype.Repository;
import org.springframework.transaction.annotation.Transactional;
import org.springframework.beans.factory.annotation.Autowired;


import com.ibatis.sqlmap.client.SqlMapClient;

import edu.unmsm.ocaa.sisocaa.integracion.dao.CuestionarioDAO;

@Repository
public class CuestionarioDAOImpl extends SqlMapClientDaoSupport implements CuestionarioDAO {

	
	@Autowired
	public CuestionarioDAOImpl(SqlMapClient sqlMapClient)
	{
		super.setSqlMapClient(sqlMapClient);
	}
	
	@Transactional(readOnly = true)
	public Object getCuestionario(Object o) throws DataAccessException {
		// TODO Auto-generated method stub
		Integer p1=(Integer)o;
		Object objs=getSqlMapClientTemplate().queryForObject("getCuestionario",p1);
		return objs;
	}
}
